package com.myboot.springbootmybatis.service.Impl;

import com.myboot.springbootmybatis.mapper.StudentMapper;
import com.myboot.springbootmybatis.pojo.Student;
import com.myboot.springbootmybatis.service.StudentService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import javax.annotation.Resource;
@Service
@Transactional
public class StudentServiceImpl implements StudentService {

    @Autowired
    private StudentMapper studentMapper;
    @Override
    public Student queryById(Integer id) {
        Student student = studentMapper.selectById(id);
        return student;
    }
}
